/*
 * To change this template, choose Tools | Templates and open the template in
 * the editor.
 */
package controllers;

import play.jobs.Job;
import models.*;
import play.jobs.OnApplicationStart;
import play.test.Fixtures;

/**
 *
 * @author jhidalgov
 */
@OnApplicationStart
public class BootStrap extends Job {

    public void doJob() {
        // Verificamos si no hay docentes
        if (Docente.count() == 0) {
            Fixtures.loadModels("initial-data.yml");
        }
    }
}